package com.shiliao.framework.ui.dilaog;


import android.app.Activity;
import android.view.Gravity;
import android.widget.TextView;

import com.shiliao.framework.R;

/**
 * 医美加载dialog
 */
public class YimeiLoadingDialog extends YimeiBaseDialog {

    private TextView mTextView;

    public YimeiLoadingDialog(Activity activity) {
        super(activity);
        if (null != activity && getLayoutInflater() != null) {
            setDialogCancelable(false);
            mDialog.setCanceledOnTouchOutside(true);
            mContainerView = getLayoutInflater().inflate(
                    R.layout.loading_dialog, null);
            mTextView = (TextView) mContainerView
                    .findViewById(R.id.widget_toast_textview);

            mWindow.setBackgroundDrawableResource(R.drawable.widget_dialog_background);
            mWindow.setGravity(Gravity.CENTER);
            setInAnimation(AnimationType.DIALOG_FADE);

        }
    }

    public void setText(CharSequence charSequence) {
        mTextView.setText(charSequence);
    }

}
